{if($paginate->count())}
    <ul class="list-unstyled">
        {volist name="$paginate->all()" id="topic"}
            <?php if($key>0){ echo('<hr>'); } ?>
            <li class="media">
                <div class="media-left">
                    <a href="{:url('user/read', ['id' => $topic->user_id])}">
                        <img class="media-object img-thumbnail mr-3" style="width: 52px; height: 52px;" src="{$topic->user->avatar}" title="{$topic->user->name}">
                    </a>
                </div>

                <div class="media-body">

                    <div class="media-heading mt-0 mb-1">
                        <a href="{:url('topic/read', ['id' => $topic->id])}" title="{$topic->title}">
                            {$topic->title}
                        </a>
                        <a class="float-right" href="{:url('topic/read', ['id' => $topic->id])}">
                            <span class="badge badge-secondary badge-pill"> {$topic->reply_count} </span>
                        </a>
                    </div>

                    <small class="media-body meta text-secondary">

                        <a class="text-secondary" href="{:url('category/read', ['id' => $topic->category_id])}" title="{$topic->category->name}">
                            <i class="far fa-folder"></i>
                            {$topic->category->name}
                        </a>

                        <span> • </span>
                        <a class="text-secondary" href="{:url('user/read', ['id' => $topic->user_id])}" title="{$topic->user->name}">
                            <i class="far fa-user"></i>
                            {$topic->user->name}
                        </a>
                        <span> • </span>
                        <i class="far fa-clock"></i>
                        <span class="timeago" title="最后活跃于：{$topic->update_time}">{$topic->update_time}</span>
                    </small>

                </div>
            </li>

        {/volist}
    </ul>
    <!-- 分页 -->
    <div class="mt-5">
        <?php echo($paginate->render()); ?>
    </div>
{else /}
    <div class="empty-block">暂无数据 ~_~ </div>
{/if}